import request from "@/utils/request";

/**
 * @function 获取列表数据
 * **/
export const listApi = (params) => {
  return request.get('/sys/user/page', {params})
}

/**
 * @function 创建用户
 * **/
export const createApi = (data) => {
  return request.post('/sys/user', data)
}

/**
 * @function 获取用户详情
 * **/
export const getInfoApi = (id) => {
  return request.get(`/sys/user/${id}`)
}

/**
 * @function 更新用户
 * **/
export const updataApi = (data) => {
  return request.put('/sys/user', data)
}

/**
 * @function 删除用户
 * **/
export const deleteApi = (ids) => {
  return request.delete('/sys/user', {data:ids})
}